#ifndef _QEXTTCPTASK_P_H
#define _QEXTTCPTASK_P_H

#include <qextTcpGlobal.h>
#include <qextTcpTask.h>

#include <QDateTime>
#include <QWaitCondition>
#include <QQueue>
#include <QPointer>
#include <QHash>
#include <QMutex>

class QEXTTcpPacketInterface;
class QEXTTcpPacketTransceiver;
class QEXTTcpTask;
class QEXT_TCP_API QEXTTcpTaskPrivate
{
public:
    explicit QEXTTcpTaskPrivate(QEXTTcpTask *q);
    virtual ~QEXTTcpTaskPrivate();

    QEXTTcpTask * const q_ptr;

    const QDateTime m_timestamp;
    QSharedPointer<QEXTTcpPacketTransceiver> m_packetTransceiver;
    QSharedPointer<QEXTTcpPacketInterface> m_receivedPacket;

    mutable QMutex m_mutex;
    bool m_finished;
    QString m_errorString;

    quint64 m_id;
    static quint64 sm_id;

private:
    Q_DECLARE_PUBLIC(QEXTTcpTask)
    Q_DISABLE_COPY(QEXTTcpTaskPrivate)
};

#endif // _QEXTTCPTASK_P_H
